package cytargetlinker.io;

import java.util.HashMap;
import java.util.Map;

import cytoscape.CyNode;

public class Edge {

	private String id;
	private Map<String, String> properties;
	private Node source;
	private Node target;
	private CyNode cySource;
	private CyNode cyTarget;
	
	public Edge(String id) {
		this.id = id;
		properties = new HashMap<String, String>();
	}
	
	public void addProperty(String key, String value) {
		if(!key.equals("") && !properties.containsKey(key)) {
			properties.put(key, value);
		}
	}
	
	// SETTERS & GETTERS

	public String getId() {
		return id;
	}

	public Map<String, String> getProperties() {
		return properties;
	}

	public Node getSource() {
		return source;
	}

	public void setSource(Node source) {
		this.source = source;
	}

	public Node getTarget() {
		return target;
	}

	public void setTarget(Node target) {
		this.target = target;
	}

	public CyNode getCySource() {
		return cySource;
	}

	public void setCySource(CyNode cySource) {
		this.cySource = cySource;
	}

	public CyNode getCyTarget() {
		return cyTarget;
	}

	public void setCyTarget(CyNode cyTarget) {
		this.cyTarget = cyTarget;
	}
}
